#include <iostream>
using namespace std;

int main() {
    cout.setf(ios::fixed, ios::floatfield);

    // 整型int 转 单精度浮点数float
    float tree = 3;

    // 双精度浮点数double 转 整型int
    int guess(3.9832);

    // 双精度浮点数double 转 整型int, 超出int表示范围，结果未定义(不同编译器结果可能不一样)
    int debt = 7.2E12;

    cout << "tree = " << tree << endl;
    cout << "guess = " << guess << endl;
    cout << "debt = " << debt << endl;
}